Adaptive loop filtering (ALF) for video coding

ABSTRACT

A method for adaptive loop filtering of a reconstructed picture in a video encoder is provided that includes determining whether or not sample adaptive offset (SAO) filtering is applied to the reconstructed picture, and using adaptive loop filtering with no offset for the reconstructed picture when the SAO filtering is determined to be applied to the reconstructed picture.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application claims benefit of U.S. Provisional Patent ApplicationSer. No. 61/578,066 filed Dec. 20, 2011, and U.S. Provisional PatentApplication Ser. No. 61/587,032 filed Jan. 16, 2012, which areincorporated herein by reference in their entirety.

BACKGROUND OF THE INVENTION

1. Field of the Invention

Embodiments of the present invention generally relate to adaptive loopfiltering for video coding.

2. Description of the Related Art

The Joint Collaborative Team on Video Coding (JCT-VC) of ITU-T WP3/16and ISO/IEC JTC 1/SC 29/WG 11 is currently developing thenext-generation video coding standard referred to as High EfficiencyVideo Coding (HEVC). HEVC is expected to provide around 50% reduction inbit rate (at similar visual quality) over the current standard,H.264/AVC, and intended to support larger resolutions and higher framerates. To address these requirements, HEVC utilizes larger block sizesthan H.264/AVC. In HEVC, the largest coding unit (LCU) can be up to64×64 in size, while in H.264/AVC, the macroblock size is fixed at16×16.

In a coding scheme that uses block-based prediction, transform coding,and quantization, some characteristics of the compressed video data maydiffer from the original video data. For example, discontinuitiesreferred to as blocking artifacts can occur in the reconstructed signalat block boundaries. Quantization errors, ringing artifacts, and highfrequency noise can also occur. Further, the intensity of the compressedvideo data may be shifted. Such intensity shift may also cause visualimpairments or artifacts. To help reduce such artifacts in decompressedvideo, three in-loop filters have been proposed for the emerging HEVCstandard: a deblocking filter to reduce blocking artifacts, a sampleadaptive offset filter (SAO) to reduce distortion caused by intensityshift and high frequency noise, and an adaptive loop filter (ALF) tominimize the mean squared error (MSE) between reconstructed video andoriginal video

SUMMARY

Embodiments of the present invention relate to apparatus and methodsadaptive loop filtering in video coding. In one aspect, a method foradaptive loop filtering of a reconstructed picture in a video encoder,wherein parameters of an adaptive loop filter include a plurality ofcoefficients and an offset, is provided that includes determiningwhether or not sample adaptive offset (SAO) filtering is applied to thereconstructed picture and using adaptive loop filtering with no offsetfor the reconstructed picture when the SAO filtering is determined to beapplied to the reconstructed picture.

In one aspect, a method for adaptive loop filtering of a reconstructedpicture in a video decoder, wherein parameters of an adaptive loopfilter include a plurality of coefficients and an offset, is providedthat includes determining whether or not adaptive loop filtering with nooffset is to be applied to the reconstructed picture, decoding filterparameters for an adaptive loop filter wherein a value of the offset isnot included in the filter parameters when adaptive loop filtering withno offset is to be applied, and applying the adaptive loop filter to atleast some pixels of a portion of the reconstructed picture using thedecoded filter parameters, wherein a value of the offset is assumed tobe zero.

In one aspect, an apparatus configured for adaptive loop filtering of areconstructed picture in a video encoder, wherein parameters of anadaptive loop filter comprise a plurality of coefficients and an offset,the apparatus including means for determining whether or not sampleadaptive offset (SAO) filtering is applied to the reconstructed picture,means for using adaptive loop filtering with no offset for thereconstructed picture when the SAO filtering is determined to be appliedto the reconstructed picture, and means for using adaptive loopfiltering with a computed offset for the reconstructed picture when theSAO filtering is determined to not be applied.

BRIEF DESCRIPTION OF THE DRAWINGS

Particular embodiments will now be described, by way of example only,and with reference to the accompanying drawings:

FIG. 1 illustrates filtering regions of a picture in region-basedadaptive loop filtering (ALF);

FIG. 2 illustrates prior art signaling of ALF parameters and ALF codingunit flags in region-based ALF;

FIG. 3 is an overview of ALF;

FIG. 4 shows an example 10-tap symmetric finite impulse response (FIR)filter;

FIG. 5 is a block diagram of a digital system;

FIG. 6 is a block diagram of a video encoder;

FIG. 7 is a block diagram of a video decoder;

FIGS. 8 and 9 are flow diagrams of methods; and

FIG. 10 is a block diagram of an illustrative digital system.

DETAILED DESCRIPTION OF EMBODIMENTS OF THE INVENTION

Specific embodiments of the invention will now be described in detailwith reference to the accompanying figures. Like elements in the variousfigures are denoted by like reference numerals for consistency.

As used herein, the term “picture” may refer to a frame or a field of aframe. A frame is a complete image captured during a known timeinterval. For convenience of description, embodiments of the inventionare described herein in reference to HEVC. One of ordinary skill in theart will understand that embodiments of the invention are not limited toHEVC.

In HEVC, a largest coding unit (LCU) is the base unit used forblock-based coding. A picture is divided into non-overlapping LCUs. Thatis, an LCU plays a similar role in coding as the macroblock ofH.264/AVC, but it may be larger, e.g., 32×32, 64×64, etc. An LCU may bepartitioned into coding units (CU). A CU is a block of pixels within anLCU and the CUs within an LCU may be of different sizes. Thepartitioning is a recursive quadtree partitioning. The quadtree is splitaccording to various criteria until a leaf is reached, which is referredto as the coding node or coding unit. The maximum hierarchical depth ofthe quadtree is determined by the size of the smallest CU (SCU)permitted. The coding node is the root node of two trees, a predictiontree and a transform tree. A prediction tree specifies the position andsize of prediction units (PU) for a coding unit. A transform treespecifies the position and size of transform units (TU) for a codingunit. A transform unit may not be larger than a coding unit. In recentspecifications, the size of a square transform unit may be 4×4, 8×8,16×16, and 32×32 and the size of a non-square transform may be 16×4,4×16, 32×8, and 8×32. The sizes of the transforms units and predictionunits for a CU are determined by the video encoder during predictionbased on minimization of rate/distortion costs.

Various versions of HEVC are described in the following documents, whichare incorporated by reference herein: T. Wiegand, et al., “WD3: WorkingDraft 3 of High-Efficiency Video Coding,” JCTVC-E603, JointCollaborative Team on Video Coding (JCT-VC) of ITU-T SG16 WP3 andISO/IEC JTC1/SC29/WG11, Geneva, CH, Mar. 16-23, 2011 (“WD3”), B. Bross,et al., “WD4: Working Draft 4 of High-Efficiency Video Coding,”JCTVC-F803_d6, Joint Collaborative Team on Video Coding (JCT-VC) ofITU-T SG16 WP3 and ISO/IEC JTC1/SC29/WG11, Torino, IT, Jul. 14-22, 2011(“WD4”), B. Bross. et al., “WD5: Working Draft 5 of High-EfficiencyVideo Coding,” JCTVC-G1103_d9, Joint Collaborative Team on Video Coding(JCT-VC) of ITU-T SG16 WP3 and ISO/IEC JTC1/SC29/WG11, Geneva, CH, Nov.21-30, 2011 (“WD5”), B. Bross, et al., “High Efficiency Video Coding(HEVC) Text Specification Draft 6,” JCTVC-H1003, Joint CollaborativeTeam on Video Coding (JCT-VC) of ITU-T SG16 WP3 and ISO/IECJTC1/SC29/WG1, Geneva, CH, Nov. 21-30, 2011 (“HEVC Draft 6”), B. Bross,et al., “High Efficiency Video Coding (HEVC) Text Specification Draft7,” JCTVC-I1003_d0, Joint Collaborative Team on Video Coding (JCT-VC) ofITU-T SG16 WP3 and ISO/IEC JTC1/SC29/WG1, Geneva, CH, Apr. 17-May 7,2012 (“HEVC Draft 7”), and B. Bross, et al., “High Efficiency VideoCoding (HEVC) Text Specification Draft 8,” JCTVC-J1003_d7, JointCollaborative Team on Video Coding (JCT-VC) of ITU-T SG16 WP3 andISO/IEC JTC1/SC29/WG1, Stockholm, SE, Jul. 11-20, 2012 (“HEVC Draft 8”).

In general, in adaptive loop filtering (ALF), symmetric 2D finiteimpulse response (FIR) filters are applied to blocks of a reconstructedpicture to minimize the error between the original input blocks and thereconstructed blocks. The shape of a filter may be diamond, circle,star, cross, or any other general shape bounded by a (2V+1)×(2H+1)rectangle where V is the vertical dimension of the filter and H is thehorizontal dimension of the filter. In practice, the filter shape orshapes to be used are defined by the video code standard, e.g., HEVC.The coefficients of the filters to be applied to each reconstructedpicture are determined by the encoder and signaled to the decoder.

Several different approaches have been proposed for ALF. The originalALF concept is explained in more detail in Y. Chiu and L. Xu, “Adaptive(Wiener) Filter for Video Compression,” ITU-T SG16 Contribution, C437,Geneva, CH, April 2008. As originally proposed in Y. Chiu and L. Xu,“Adaptive (Wiener) Filter for Video Compression,” ITU-T SG16Contribution, C437, Geneva, CH, April 2008, ALF used square filters andwas carried out on entire deblocked pictures. Block-based ALF, describedin T. Chujoh, et al., “Block-based Adaptive Loop Filter,” ITU-T SG16 Q.6Document, VCEG-A118, Berlin, Del., July 2008, has also proposed in whichALF could be enabled and disabled on a block, i.e., coding unit, basis.In block-based ALF, the encoder signals to the decoder the map of blocksof a deblocked picture on which ALF is to be applied.

A further refinement to block-based ALF, quadtree adaptive loopfiltering in which the map of blocks is signaled using a quadtree, hasbeen proposed in T. Chujoh, et al., “Quadtree-based Adaptive LoopFilter,” ITU-T SG16 Contribution, C181, January 2009. The use of diamondshaped rather than square shaped ALF filters has also been proposed toreduce computational complexity. Diamond shaped ALF filters for lumacomponents are described in M. Karczewicz, et. al., “A Hybrid VideoCoder Based on Extended Macroblock Sizes, Improved Interpolation, andFlexible Motion Representation,” IEEE Trans. on Circuits and Systems forVideo Technology, pp. 1698-1708, Vol. 20, No. 12, December 2010. Otherrefinements to ALF have been proposed in M. Budagavi, et al, “ReducedComplexity Adaptive Loop Filter (ALF) for Video Coding,” U.S. PatentApplication No. 20120177104, filed Jan. 11, 2012.

Region-based ALF has also been proposed. As illustrated in FIG. 1, inregion-based ALF, a picture is divided into 16 LCU-aligned regions.These regions may be referred to as filtering regions herein. In FIG. 1,the dashed lines delineate the ALF filtering regions and the solid linesdelineate the picture. An LCU-aligned region of a picture is a region inwhich the region boundaries are also LCU boundaries. It is recognizedthat the dimensions of a picture and the dimensions of an LCU may notallow a picture to be evenly divided into LCUs. As illustrated in FIG.1, there may be blocks at the bottom of the picture or the right side ofthe picture that are smaller than the actual LCU size, i.e., partialLCUs. These partial LCUs are mostly treated as if they were full LCUsand are referred to as LCUs.

For each picture, the encoder determines filter parameters for eachregion and signals those parameters to the decoder. In some region-basedALF approaches, the encoder may also select a filter shape for a picturefrom multiple filter shapes. As part of determining the filterparameters, the encoder may apply a coding cost versus error decreaseanalysis to decide whether or not a particular region is to be filtered.If a region is not to be filtered, no parameters are signaled for thatregion. Further, one or more regions may use the same parameters. Thus,the encoder may signal a maximum of 16 sets of parameters and may signalfewer. The encoder may also analyze application of the filtering at theCU level within a region and turn the filtering on and off at the CUlevel. FIG. 2 illustrates a recently proposed signaling of the ALFparameters and CU level information from the encoder to the decoder. Asshown, the filter parameters for a picture are signaled in the pictureparameter set (PPS) and the application of filtering at the CU level issignaled in each slice header.

For simplicity of explanation herein, unless otherwise stated, the abovedescribed region-based ALF with one 10-tap filter is assumed. One ofordinary skill in the art, having benefit of this disclosure, willunderstand that techniques for adaptive loop filtering with no offsetdescribed herein may be used in other ALF approaches, with other filtersizes, and/or with multiple filter shapes.

FIG. 3 is an overview of adaptive loop filtering (ALF). A symmetric FIRfilter H(z₁,z₂) may be applied to reconstructed pixels p(x,y) of regionsof a reconstructed picture after application of a deblocking filter anda sample adaptive offset (SAO) filter to generate filtered pixelsq(x,y). As previously mentioned, the shape of a filter may be diamond,circle, star, cross, or any other general shape bounded by a(2V+1)×(2H+1) rectangle where V is the vertical dimension of the filterand H is the horizontal dimension of the filter.

The filter parameters are the coefficients h_(ij) and an offset b₀. Theoffset is applied to compensate for intensity shifts in a picture (whichmay vary from region to region) that may be introduced by theblock-based coding process. The filtered output q(x,y) for a pixelp(x,y) is given by

${q\left( {x,y} \right)} = {{\sum\limits_{i = {- V}}^{V}{\sum\limits_{j = {- H}}^{H}{h_{ij}{p\left( {{x - i},{y - j}} \right)}}}} + b_{0}}$

The filter parameters for a region are determined using a Weinerfiltering technique in which the objective is to determine parameterssuch that the mean squared error between the original input pixel andthe filtered reconstructed pixel is minimized, i.e.,{h _(ij) b ₀}=arg min E{e ²(x,y)}where the error is given bye(x,y)=r(x,y)−q(x,y)and r(x,y) is the original pixel value from the input picture.

The solution of the two-dimensional (2D) problem of FIG. 3 can be mappedto a one-dimensional (1D) problem by appropriately scanning thetwo-dimensional filter grid (along with averaging of pixels when thefilter is symmetric) to form 1D vectors. This mapping is explained usingthe example symmetric 10 tap 2D finite impulse response (FIR) filter ofFIG. 4. The notation of c_(i) is used to denote filter coefficientsinstead of h_(ij) to illustrate the symmetry in the filter.

The output q(x,y) of this example filter for a pixel p(x,y) is given byq(x,y)=b ₀ +c ₀(p(x,y−3)+p(x,y+3))+c ₁(p(x,y−2)+p(x,y+2))+ . . . +c ₉p(x,y)where c_(i), j=0 . . . 9 is a filter coefficient. Let

p₀(x, y) = (p(x, y − 3) + p(x, y + 3))p₁(x, y) = (p(x, y − 2) + p(x, y + 2)) ⋮ p₉(x, y) = p(x, y)The filtering computation then reduces toq(x,y)=b ₀+Σ_(i=0) ⁹ c _(i) p _(i)(x,y).

As previously mentioned, the filter parameters are determined using astandard Weiner filtering technique in which the objective is todetermine parameters such that the mean squared error between theoriginal input pixel and the filtered reconstructed pixel is minimized,i.e., to find values for the coefficients c_(i) and the offset b₀ thatminimizeΣ_(x,y)(q(x,y)−r(x,y))².Using the standard Weiner filtering technique, the parameter estimationmay be expressed as

$\begin{matrix}{{\begin{bmatrix}{R_{p}\left\lbrack {0,0} \right\rbrack} & {R_{p}\left\lbrack {0,1} \right\rbrack} & \ldots & {R_{p}\left\lbrack {0,N} \right\rbrack} & {m_{p}\lbrack 0\rbrack} \\{R_{p}\left\lbrack {1,0} \right\rbrack} & {R_{p}\left\lbrack {1,1} \right\rbrack} & \ldots & {R_{p}\left\lbrack {1,{N - 1}} \right\rbrack} & {m_{p}\lbrack 1\rbrack} \\\vdots & \vdots & \ddots & \vdots & \vdots \\{R_{p}\left\lbrack {N,0} \right\rbrack} & {R_{p}\left\lbrack {N,1} \right\rbrack} & \ldots & {R_{p}\left\lbrack {N,N} \right\rbrack} & {m_{p}\lbrack N\rbrack} \\{m_{p}\lbrack 0\rbrack} & {m_{p}\lbrack 1\rbrack} & \ldots & {m_{p}\lbrack N\rbrack} & 1\end{bmatrix}\begin{bmatrix}c_{0} \\c_{1} \\\vdots \\c_{N} \\b_{0}\end{bmatrix}} = {\quad{{\begin{bmatrix}{R_{pr}\lbrack 0\rbrack} \\{R_{pr}\lbrack 1\rbrack} \\\vdots \\{R_{pr}\lbrack N\rbrack} \\m_{r}\end{bmatrix}\mspace{79mu}{where}\mspace{79mu}{m_{p}\lbrack i\rbrack}} = {{\sum\limits_{x,y}{{p_{i}\left( {x,y} \right)}\mspace{79mu}{R_{p}\left\lbrack {i,j} \right\rbrack}}} = {{\sum\limits_{x,y}{{p_{i}\left( {x,y} \right)}{p_{j}\left( {x,y} \right)}\mspace{79mu} m_{r}}} = {{\sum\limits_{x,y}{{r\left( {x,y} \right)}\mspace{79mu}{R_{pr}\lbrack i\rbrack}}} = {\sum\limits_{x,y}{{p_{i}\left( {x,y} \right)}{{r\left( {x,y} \right)}.}}}}}}}}} & \left( {{Eq}.\mspace{14mu} 1} \right)\end{matrix}$R_(p) is the auto-correlation of p_(i)(x,y) and R_(pr) is thecross-correlation of p_(i) with r (the original signal). N+1 is thenumber of filter taps. For example, for the filter of FIG. 4, N=9.Computation of the solution involves matrix inversion using Choleskydecomposition or other techniques for symmetric matrices. If the matrixsize is M×M, the computation complexity is O(M³) and the memory requiredis O(M²). The application of the filter with the determined parametersmay be computed as perq(x,y)=b ₀+Σ_(i=0) ^(N) c _(i) p _(i)(x,y).  (Eq. 2)

As previously mentioned, a sample adaptive offset (SAO) in-loop filteris one of the in-loop filters proposed in the emerging HEVC standard.SAO, if used, may be applied to reconstructed pixels after applicationof a deblocking filter and before application of ALF. In general, SAOinvolves adding an offset to compensate for intensity shift directly toa reconstructed pixel. The value of the offset depends on the localcharacteristics surrounding the pixel, i.e., edge direction/shape and/orpixel intensity level. There are two techniques that may be used fordetermining offset values: band offset (BO) and edge offset (EO).Additional details regarding the various proposals for SAO may be found,for example, in the previously mentioned working drafts of the HEVCspecification.

The offset added to a reconstructed pixel by SAO and the offset added toa reconstructed pixel by ALF are both intended to compensate forintensity shift. Accordingly, when SAO is applied prior to ALF, the ALFoffset b₀ can be assumed to be zero. Some embodiments of the inventionprovide for ALF with no offset when SAO is also used, i.e., the offsetfor ALF is assumed to be zero. If SAO is disabled, ALF with an offset isused. The assumption that the offset b₀ is zero results in asimplification of the Weiner filter estimation in the encoder. That is,with no need to determine an offset, the parameter estimation may beexpressed as

$\begin{matrix}{{\begin{bmatrix}{R_{p}\left\lbrack {0,0} \right\rbrack} & {R_{p}\left\lbrack {0,1} \right\rbrack} & \ldots & {R_{p}\left\lbrack {0,N} \right\rbrack} & {m_{p}\lbrack 0\rbrack} \\{R_{p}\left\lbrack {1,0} \right\rbrack} & {R_{p}\left\lbrack {1,1} \right\rbrack} & \ldots & {R_{p}\left\lbrack {1,{N - 1}} \right\rbrack} & {m_{p}\lbrack 1\rbrack} \\\vdots & \vdots & \ddots & \vdots & \vdots \\{R_{p}\left\lbrack {N,0} \right\rbrack} & {R_{p}\left\lbrack {N,1} \right\rbrack} & \ldots & {R_{p}\left\lbrack {N,N} \right\rbrack} & {m_{p}\lbrack N\rbrack}\end{bmatrix}\begin{bmatrix}c_{0} \\c_{1} \\\vdots \\c_{N}\end{bmatrix}} = {\quad\begin{bmatrix}{R_{pr}\lbrack 0\rbrack} \\{R_{pr}\lbrack 1\rbrack} \\\vdots \\{R_{pr}\lbrack N\rbrack}\end{bmatrix}}} & \left( {{Eq}.\mspace{14mu} 3} \right)\end{matrix}$If N=9, then the solution of the above equation involves inversion of a10×10 matrix as compared to inversion of an 11×11 matrix is the offsetis also determined. Further, the addition of the offset when the filteris applied in the encoder and decoder may be eliminated, i.e., theapplication of the filter may be computed as perq(x,y)=Σ_(i=0) ^(N) c _(i) p _(i)(x,y).  (Eq. 4)

The previously described signaling of filter parameters for region-basedALF causes a full picture delay in the encoder before data can betransmitted since the filter parameters for the entire picture aresignaled in the picture parameter set. Some embodiments of the inventionprovide alternatives for signaling the filter parameters that reducethis delay.

FIG. 5 shows a block diagram of a digital system that includes a sourcedigital system 500 that transmits encoded video sequences to adestination digital system 502 via a communication channel 516. Thesource digital system 500 includes a video capture component 504, avideo encoder component 506, and a transmitter component 508. The videocapture component 504 is configured to provide a video sequence to beencoded by the video encoder component 506. The video capture component504 may be, for example, a video camera, a video archive, or a videofeed from a video content provider. In some embodiments, the videocapture component 504 may generate computer graphics as the videosequence, or a combination of live video, archived video, and/orcomputer-generated video.

The video encoder component 506 receives a video sequence from the videocapture component 504 and encodes it for transmission by the transmittercomponent 508. The video encoder component 506 receives the videosequence from the video capture component 504 as a sequence of pictures,divides the pictures into largest coding units (LCUs), and encodes thevideo data in the LCUs. As part of the encoding process, the videoencoder component 506 may perform an embodiment of adaptive loopfiltering and/or signaling of ALF parameters as described herein. Anembodiment of the video encoder component 506 is described in moredetail herein in reference to FIG. 6.

The transmitter component 508 transmits the encoded video data to thedestination digital system 502 via the communication channel 516. Thecommunication channel 516 may be any communication medium, orcombination of communication media suitable for transmission of theencoded video sequence, such as, for example, wired or wirelesscommunication media, a local area network, or a wide area network.

The destination digital system 502 includes a receiver component 510, avideo decoder component 512 and a display component 514. The receivercomponent 510 receives the encoded video data from the source digitalsystem 500 via the communication channel 516 and provides the encodedvideo data to the video decoder component 512 for decoding. The videodecoder component 512 reverses the encoding process performed by thevideo encoder component 506 to reconstruct the LCUs of the videosequence. As part of the decoding process, the video decoder component512 may perform an embodiment of adaptive loop filtering according tosignaling from the encoder as described herein. An embodiment of thevideo decoder component 512 is described in more detail below inreference to FIG. 7.

The reconstructed video sequence is displayed on the display component514. The display component 514 may be any suitable display device suchas, for example, a plasma display, a liquid crystal display (LCD), alight emitting diode (LED) display, etc.

In some embodiments, the source digital system 500 may also include areceiver component and a video decoder component and/or the destinationdigital system 502 may include a transmitter component and a videoencoder component for transmission of video sequences both directionsfor video steaming, video broadcasting, and video telephony. Further,the video encoder component 506 and the video decoder component 512 mayperform encoding and decoding in accordance with one or more videocompression standards. The video encoder component 506 and the videodecoder component 512 may be implemented in any suitable combination ofsoftware, firmware, and hardware, such as, for example, one or moredigital signal processors (DSPs), microprocessors, discrete logic,application specific integrated circuits (ASICs), field-programmablegate arrays (FPGAs), etc.

FIG. 6 is a block diagram of the LCU processing portion of an examplevideo encoder. A coding control component (not shown) sequences thevarious operations of the LCU processing, i.e., the coding controlcomponent runs the main control loop for video encoding. The codingcontrol component receives a digital video sequence and performs anyprocessing on the input video sequence that is to be done at the picturelevel, such as determining the coding type (I, P, or B) of a picturebased on the high level coding structure, e.g., IPPP, IBBP,hierarchical-B, and dividing a picture into LCUs for further processing.

In addition, for pipelined architectures in which multiple LCUs may beprocessed concurrently in different components of the LCU processing,the coding control component controls the processing of the LCUs byvarious components of the LCU processing in a pipeline fashion. Forexample, in many embedded systems supporting video processing, there maybe one master processor and one or more slave processing modules, e.g.,hardware accelerators. The master processor operates as the codingcontrol component and runs the main control loop for video encoding, andthe slave processing modules are employed to off load certaincompute-intensive tasks of video encoding such as motion estimation,motion compensation, intra prediction mode estimation, transformationand quantization, entropy coding, and loop filtering. The slaveprocessing modules are controlled in a pipeline fashion by the masterprocessor such that the slave processing modules operate on differentLCUs of a picture at any given time. That is, the slave processingmodules are executed in parallel, each processing its respective LCUwhile data movement from one processor to another is serial.

The LCU processing receives LCUs 600 of the input video sequence fromthe coding control component and encodes the LCUs 600 under the controlof the coding control component to generate the compressed video stream.The LCUs 600 in each picture are processed in row order. The LCUs 600from the coding control component are provided as one input of a motionestimation component (ME) 620, as one input of an intra-predictionestimation component (IPE) 624, and to a positive input of a combiner602 (e.g., adder or subtractor or the like). Further, although notspecifically shown, the prediction mode of each picture as selected bythe coding control component is provided to a mode decision component628 and the entropy coding component 636.

The storage component 618 provides reference data to the motionestimation component 620 and to the motion compensation component 622.The reference data may include one or more previously encoded anddecoded pictures, i.e., reference pictures.

The motion estimation component 620 provides motion data information tothe motion compensation component 622 and the entropy coding component636. More specifically, the motion estimation component 620 performstests on CUs in an LCU based on multiple inter-prediction modes (e.g.,skip mode, merge mode, and normal or direct inter-prediction), PU sizes,and TU sizes using reference picture data from storage 618 to choose thebest CU partitioning, PU/TU partitioning, inter-prediction modes, motionvectors, etc. based on coding cost, e.g., a rate distortion coding cost.To perform the tests, the motion estimation component 620 may divide anLCU into CUs according to the maximum hierarchical depth of thequadtree, and divide each CU into PUs according to the unit sizes of theinter-prediction modes and into TUs according to the transform unitsizes, and calculate the coding costs for each PU size, prediction mode,and transform unit size for each CU. The motion estimation component 620provides the motion vector (MV) or vectors and the prediction mode foreach PU in the selected CU partitioning to the motion compensationcomponent (MC) 622.

The motion compensation component 622 receives the selectedinter-prediction mode and mode-related information from the motionestimation component 620 and generates the inter-predicted CUs. Theinter-predicted CUs are provided to the mode decision component 628along with the selected inter-prediction modes for the inter-predictedPUs and corresponding TU sizes for the selected CU/PU/TU partitioning.The coding costs of the inter-predicted CUs are also provided to themode decision component 628.

The intra-prediction estimation component 624 (IPE) performsintra-prediction estimation in which tests on CUs in an LCU based onmultiple intra-prediction modes, PU sizes, and TU sizes are performedusing reconstructed data from previously encoded neighboring CUs storedin a buffer (not shown) to choose the best CU partitioning, PU/TUpartitioning, and intra-prediction modes based on coding cost, e.g., arate distortion coding cost. To perform the tests, the intra-predictionestimation component 624 may divide an LCU into CUs according to themaximum hierarchical depth of the quadtree, and divide each CU into PUsaccording to the unit sizes of the intra-prediction modes and into TUsaccording to the transform unit sizes, and calculate the coding costsfor each PU size, prediction mode, and transform unit size for each PU.The intra-prediction estimation component 624 provides the selectedintra-prediction modes for the PUs, and the corresponding TU sizes forthe selected CU partitioning to the intra-prediction component (IP) 626.The coding costs of the intra-predicted CUs are also provided to theintra-prediction component 626.

The intra-prediction component 626 (IP) receives intra-predictioninformation, e.g., the selected mode or modes for the PU(s), the PUsize, etc., from the intra-prediction estimation component 624 andgenerates the intra-predicted CUs. The intra-predicted CUs are providedto the mode decision component 628 along with the selectedintra-prediction modes for the intra-predicted PUs and corresponding TUsizes for the selected CU/PU/TU partitioning. The coding costs of theintra-predicted CUs are also provided to the mode decision component628.

The mode decision component 628 selects between intra-prediction of a CUand inter-prediction of a CU based on the intra-prediction coding costof the CU from the intra-prediction component 626, the inter-predictioncoding cost of the CU from the motion compensation component 622, andthe picture prediction mode provided by the coding control component.Based on the decision as to whether a CU is to be intra- or inter-coded,the intra-predicted PUs or inter-predicted PUs are selected. Theselected CU/PU/TU partitioning with corresponding modes and other moderelated prediction data (if any) such as motion vector(s) and referencepicture index (indices), are provided to the entropy coding component636.

The output of the mode decision component 628, i.e., the predicted PUs,is provided to a negative input of the combiner 602 and to the combiner638. The associated transform unit size is also provided to thetransform component 604. The combiner 602 subtracts a predicted PU fromthe original PU. Each resulting residual PU is a set of pixel differencevalues that quantify differences between pixel values of the original PUand the predicted PU. The residual blocks of all the PUs of a CU form aresidual CU for further processing.

The transform component 604 performs block transforms on the residualCUs to convert the residual pixel values to transform coefficients andprovides the transform coefficients to a quantize component 606. Morespecifically, the transform component 604 receives the transform unitsizes for the residual CU and applies transforms of the specified sizesto the CU to generate transform coefficients. Further, the quantizecomponent 606 quantizes the transform coefficients based on quantizationparameters (QPs) and quantization matrices provided by the codingcontrol component and the transform sizes and provides the quantizedtransform coefficients to the entropy coding component 636 for coding inthe bit stream.

The entropy coding component 636 entropy encodes the relevant data,i.e., syntax elements, output by the various encoding components and thecoding control component using context-adaptive binary arithmetic coding(CABAC) to generate the compressed video bit stream. Among the syntaxelements that are encoded are picture parameter sets, flags indicatingthe CU/PU/TU partitioning of an LCU, the prediction modes for the CUs,and the quantized transform coefficients for the CUs. The entropy codingcomponent 636 also codes relevant data for in-loop filtering such as ALFparameters and ALF CU-level on/off flags, and SAO parameters, e.g.,filter type, on/off flags, and offsets, as needed.

The LCU processing component 642 includes an embedded decoder. As anycompliant decoder is expected to reconstruct an image from a compressedbit stream, the embedded decoder provides the same utility to the videoencoder. Knowledge of the reconstructed input allows the video encoderto transmit the appropriate residual energy to compose subsequentpictures.

The quantized transform coefficients for each CU are provided to aninverse quantize component (IQ) 612, which outputs a reconstructedversion of the transform result from the transform component 604. Thedequantized transform coefficients are provided to the inverse transformcomponent (IDCT) 614, which outputs estimated residual informationrepresenting a reconstructed version of a residual CU. The inversetransform component 614 receives the transform unit size used togenerate the transform coefficients and applies inverse transform(s) ofthe specified size to the transform coefficients to reconstruct theresidual values. The inverse transform component 614 may perform theinverse transform computations using the same unified forward andinverse transform architecture as the transform component 604. Thereconstructed residual CU is provided to the combiner 638.

The combiner 638 adds the original predicted CU to the residual CU togenerate a reconstructed CU, which becomes part of reconstructed picturedata. The reconstructed picture data is stored in a buffer (not shown)for use by the intra-prediction estimation component 624.

Various in-loop filters may be applied to the reconstructed picture datato improve the quality of the reference picture data used forencoding/decoding of subsequent pictures. The in-loop filters mayinclude a deblocking filter 630, a sample adaptive offset filter (SAO)632, and an adaptive loop filter (ALF) 634. The in-loop filters 630,632, 634 are applied to each reconstructed LCU in the picture and thefinal filtered reference picture data is provided to the storagecomponent 618.

The ALF component 634 includes functionality to determine filterparameters, i.e., filter coefficient values and an offset value, foreach of the 16 LCU-aligned regions of the reconstructed picture. As partof this determination, the ALF component 634 may decide that one or moreof the regions are not to be filtered (in which case filter parametersare not signaled for such regions) and/or may turn ALF filtering on andoff at the CU level. In some embodiments, when SAO filtering has beenapplied to the reconstructed picture, the offset for the ALF filter isassumed to be zero. In such embodiments, there is no need to determinethe offset and the parameter estimation may be performed as per Eq. 3.If SAO filtering has not been applied to the reconstructed picture, theoffset is determined along with the filter coefficients as per theparameter estimation of Eq. 1.

As previously described, in the prior art, each set of ALF filterparameters signaled to the decoder includes the coefficient values andthe offset value. In some embodiments in which the offset is assumed tobe zero, a flag indicating whether or not ALF with no offset is used issignaled, e.g., in the sequence parameter set, the picture parameterset, or at the slice level, and the offset value is not included in theALF filter parameters signaled to the decoder. In some embodiments inwhich the offset is assumed to be zero, rather than explicitly signalingthe use of ALF with no offset to the decoder, the offset in eachsignaled ALF filter parameter set is set to zero. In such embodiments,the decoder operates the same way for both ALF in which the offsets arecomputed and ALF in which the offsets are assumed to be zero.

In some embodiments, the encoder may signal the ALF parameters for apicture at the PPS level as previously described in reference to FIG. 2.In some embodiments, the encoder may signal the ALF parameters for eachrow of filtering regions rather than at the picture level. For example,referring to FIG. 1, the ALF component 634 may determine filterparameters for each of the four filtering regions in the first row ofthe picture. Note that there will be a maximum of four sets of filterparameters for the row and there may be fewer. Once the filterparameters are determined for that row, the encoder may cause theentropy coding component 636 to encode and output the data for theseregions along with the filter parameters determined for the row ofregions. The parameters may be output either prior to the encoded dataof the regions or immediately following the encoded data of the regions.This process is repeated for each row of filtering regions in thepicture such that the ALF filter parameters for the rows of regions areinterleaved with the encoded data of the rows of regions.

In some embodiments, the encoder may signal the ALF parameters for eachregion rather than at the picture level. For example, referring to FIG.1, the ALF component 634 may determine filter parameters for the firstfiltering region in the first row of the picture. Once the filterparameters are determined for that region, the encoder may cause theentropy coding component 636 to encode and output the data for thisregion along with the filter parameters determined for the region (ifany). The parameters may be output either prior to the encoded data ofthe region or immediately following the encoded data of the region. Thisprocess is repeated for each of the filtering regions in the picturesuch that the ALF filter parameters for the regions are interleaved withthe encoded data of the regions.

FIG. 7 is a block diagram of an example video decoder. The entropydecoding component 700 receives an entropy encoded (compressed) videobit stream and reverses the entropy encoding using CABAC decoding torecover the encoded syntax elements, e.g., CU, PU, and TU structures ofLCUs, quantized transform coefficients for CUs, motion vectors,prediction modes, in-loop filter parameters, etc. The decoded syntaxelements are passed to the various components of the decoder as needed.For example, decoded prediction modes are provided to theintra-prediction component (IP) 714 or motion compensation component(MC) 710. If the decoded prediction mode is an inter-prediction mode,the entropy decoder 700 reconstructs the motion vector(s) as needed andprovides the motion vector(s) to the motion compensation component 710.Further, decoded ALF filter parameters are passed to the ALF component720.

In some embodiments, the entropy decoding component 700 decodes ALFfilter parameters responsive to a signaled flag indicating whether ornot ALF with no offset is used. In such embodiments, if the flagindicates that ALF with no offset is used, the entropy decodingcomponent 700 decodes any ALF filter parameters present in the bitstream for the picture assuming that no offsets are included. Otherwise,the entropy decoding component 700 decodes the ALF filter parametersassuming offsets are included.

The inverse quantize component (IQ) 702 de-quantizes the quantizedtransform coefficients of the CUs. The inverse transform component 704transforms the frequency domain data from the inverse quantize component702 back to the residual CUs. That is, the inverse transform component704 applies an inverse unit transform, i.e., the inverse of the unittransform used for encoding, to the de-quantized residual coefficientsto produce reconstructed residual values of the CUs. The inversetransform component 704 may perform the inverse transform computationsusing the same unified forward and inverse transform architecture as thetransform component 604 and the inverse transform component 614 of thevideo encoder of FIG. 6.

A residual CU supplies one input of the addition component 706. Theother input of the addition component 706 comes from the mode switch708. When an inter-prediction mode is signaled in the encoded videostream, the mode switch 708 selects predicted PUs from the motioncompensation component 710 and when an intra-prediction mode issignaled, the mode switch selects predicted PUs from theintra-prediction component 714.

The motion compensation component 710 receives reference data from thestorage component 712 and applies the motion compensation computed bythe encoder and transmitted in the encoded video bit stream to thereference data to generate a predicted PU. That is, the motioncompensation component 710 uses the motion vector(s) from the entropydecoder 700 and the reference data to generate a predicted PU.

The intra-prediction component 714 receives reconstructed samples frompreviously reconstructed PUs of a current picture from the storagecomponent 712 and performs the intra-prediction computed by the encoderas signaled by an intra-prediction mode transmitted in the encoded videobit stream using the reconstructed samples as needed to generate apredicted PU.

The addition component 706 generates a reconstructed CU by adding thepredicted PUs selected by the mode switch 708 and the residual CU. Theoutput of the addition component 706, i.e., the reconstructed CUs, isstored in the storage component 712 for use by the intra-predictioncomponent 714.

In-loop filters may be applied to reconstructed picture data to improvethe quality of the decoded pictures and the quality of the referencepicture data used for decoding of subsequent pictures. The in-loopfilters are the same as those of the encoder, i.e., a deblocking filter716, a sample adaptive offset filter (SAO) 718, and an adaptive loopfilter (ALF) 720. The in-loop filters may be applied on an LCU-by-LCUbasis and the final filtered reference picture data is provided to thestorage component 712.

The ALF component 720 receives the decoded sets of filter parameters forthe sixteen LCU-aligned regions of each picture, and, for each region,applies the filter with the parameters signaled for that region (if any)and according to any other ALF information signaled by the encoder,e.g., a CU-level map. As previously mentioned, in some embodiments, theencoder may use ALF with no offset and may signal to the decoder thatALF with no offset is used. In such embodiments, the ALF component 720will not receive an explicitly encoded offset in each of the filterparameter sets, but rather assumes that the offset is zero. Thus, insuch embodiments, the ALF component 720 may apply the filter with theappropriate signaled filter coefficients to a region without the extrastep of adding an offset to each pixel (see Eq. 4).

FIG. 8 is a flow diagram of a method for adaptive loop filtering of areconstructed picture in an encoder. If SAO is not applied 800 to thereconstructed picture, filter parameters for each of the filteringregions are determined 804 for the ALF filter, the filter parameters fora filtering region including both the coefficient values of the filterand an offset. These parameters are determined as per the parameterestimation of Eq. 1. Up to sixteen sets of filter parameters may bedetermined, one for each filtering region. As previously mentioned, aspart of the determination process, the encoder may decide that one ormore regions are not to be filtered. In some embodiments, the encodermay also decide that one or more CUs within a region are not to befiltered.

If SAO is applied 800 to the reconstructed picture, filter parametersfor each of the filtering regions are determined 802 for the ALF filterassuming that the offset is zero. These parameters are determined as perthe parameter estimation of Eq. 3. Up to sixteen sets of filterparameters may be determined, one for each filtering region. Aspreviously mentioned, as part of the determination process, the encodermay decide that one or more regions are not to be filtered. In someembodiments, the encoder may also decide that one or more CUs within aregion are not to be filtered.

The filter is applied 806 to the filtering regions according to thefilter parameters. More specifically, for each filtering region that theencoder determined should be filtered, the filter is applied to pixelsof the region with the parameters determined for that region as per Eq.2. In embodiments where the encoder determines whether or not individualCUs are to be filtered, the filter is applied to pixels in those CUs theencoder decides should be filtered. In some embodiments, if the filtercoefficients are determined assuming the offset is zero, the addition ofthe offset is not performed as its value is zero (see Eq. 4).

The filter parameters are also signaled 808 in the encoded bit stream.In some embodiments, the filter parameters determined for the filteringregions are signaled in the picture parameter set as in the prior art.In some embodiments, the filter parameters are signaled for each row offiltering regions as previously described. In some embodiments, thefilter parameters are signaled for each region as previously described.In some embodiments, the encoder may explicitly signal to the decoderthat ALF with no offset is used when the SAO has been applied 800 andthe filter parameters are determined 802 assuming the offset is zero. Insuch embodiments, the signaled filter parameters do not include offsetvalues. In some embodiments, when the filter parameters are determined802 assuming the offset is zero, the offset value for each set ofsignaled filter parameters is set to zero.

FIG. 9 is a flow diagram of a method for adaptive loop filtering in adecoder assuming that the encoder explicitly signals with ALF with nooffset is used. If ALF with no offset is signaled 900, the decoderdecodes 906 any signaled parameters sets for a picture assuming that theparameter sets do not include offsets. The decoder then applies 908 theALF filter to the filtering regions of the reconstructed pictureaccording to the signaled filter parameters with no offset addition.More specifically, for each filtering region for which a parameter setis signaled, the decoder applies the ALF filter to pixels of thefiltering region according to Eq. 4 without the addition of the offsetusing the signaled parameters (coefficients) for that region.

If ALF with no offset is not signaled 900, the decoder decodes 902 anysignaled parameters sets for a picture assuming that the parameter setsinclude offsets. The decoder then applies 904 the ALF filter to thefiltering regions of the reconstructed picture according to the signaledfilter parameters with offset addition. More specifically, for eachfiltering region for which a parameter set is signaled, the decoderapplies the ALF filter to pixels of the filtering region according toEq. 2 using the signaled parameters (coefficients and offset) for thatregion.

FIG. 10 is a block diagram of an example digital system suitable for useas an embedded system that may be configured to perform ALF filtering asdescribed herein during encoding of a video stream and/or ALF filteringduring decoding of an encoded video bit stream. This examplesystem-on-a-chip (SoC) is representative of one of a family of DaVinci™Digital Media Processors, available from Texas Instruments, Inc. ThisSoC is described in more detail in “TMS320DM6467 Digital MediaSystem-on-Chip”, SPRS403G, December 2007 or later, which is incorporatedby reference herein.

The SoC 1000 is a programmable platform designed to meet the processingneeds of applications such as video encode/decode/transcode/transrate,video surveillance, video conferencing, set-top box, medical imaging,media server, gaming, digital signage, etc. The SoC 1000 providessupport for multiple operating systems, multiple user interfaces, andhigh processing performance through the flexibility of a fullyintegrated mixed processor solution. The device combines multipleprocessing cores with shared memory for programmable video and audioprocessing with a highly-integrated peripheral set on common integratedsubstrate.

The dual-core architecture of the SoC 1000 provides benefits of both DSPand Reduced Instruction Set Computer (RISC) technologies, incorporatinga DSP core and an ARM926EJ-S core. The ARM926EJ-S is a 32-bit RISCprocessor core that performs 32-bit or 16-bit instructions and processes32-bit, 16-bit, or 8-bit data. The DSP core is a TMS320C64x+TM core witha very-long-instruction-word (VLIW) architecture. In general, the ARM isresponsible for configuration and control of the SoC 1000, including theDSP Subsystem, the video data conversion engine (VDCE), and a majorityof the peripherals and external memories. The switched central resource(SCR) is an interconnect system that provides low-latency connectivitybetween master peripherals and slave peripherals. The SCR is thedecoding, routing, and arbitration logic that enables the connectionbetween multiple masters and slaves that are connected to it.

The SoC 1000 also includes application-specific hardware logic, on-chipmemory, and additional on-chip peripherals. The peripheral set includes:a configurable video port (Video Port I/F), an Ethernet MAC (EMAC) witha Management Data Input/Output (MDIO) module, a 4-bit transfer/4-bitreceive VLYNQ interface, an inter-integrated circuit (I2C) businterface, multichannel audio serial ports (McASP), general-purposetimers, a watchdog timer, a configurable host port interface (HPI);general-purpose input/output (GPIO) with programmable interrupt/eventgeneration modes, multiplexed with other peripherals, UART interfaceswith modem interface signals, pulse width modulators (PWM), an ATAinterface, a peripheral component interface (PCI), and external memoryinterfaces (EMIFA, DDR2). The video port I/F is a receiver andtransmitter of video data with two input channels and two outputchannels that may be configured for standard definition television(SDTV) video data, high definition television (HDTV) video data, and rawvideo data capture.

As shown in FIG. 10, the SoC 1000 includes two high-definitionvideo/imaging coprocessors (HDVICP) and a video data conversion engine(VDCE) to offload many video and image processing tasks from the DSPcore. The VDCE supports video frame resizing, anti-aliasing, chrominancesignal format conversion, edge padding, color blending, etc. The HDVICPcoprocessors are designed to perform computational operations requiredfor video encoding such as motion estimation, motion compensation,intra-prediction, transformation, and quantization. Further, thedistinct circuitry in the HDVICP coprocessors that may be used forspecific computation operations is designed to operate in a pipelinefashion under the control of the ARM subsystem and/or the DSP subsystem.

As was previously mentioned, the SoC 1000 may be configured to performALF filtering during video encoding and/or ALF filtering during decodingof an encoded video bit stream using methods described herein. Forexample, the coding control of the video encoder of FIG. 6 may beexecuted on the DSP subsystem or the ARM subsystem and at least some ofthe computational operations of the block processing, including theintra-prediction and inter-prediction of mode selection, transformation,quantization, and entropy encoding may be executed on the HDVICPcoprocessors. At least some of the computational operations of the ALFfiltering during encoding of a video stream may also be executed on theHDVICP coprocessors. Similarly, at least some of the computationaloperations of the various components of the video decoder of FIG. 7,including entropy decoding, inverse quantization, inversetransformation, intra-prediction, and motion compensation may beexecuted on the HDVICP coprocessors. Further, at least some of thecomputational operations of the ALF filtering during decoding of anencoded video bit stream may also be executed on the HDVICPcoprocessors.

Other Embodiments

While the invention has been described with respect to a limited numberof embodiments, those skilled in the art, having benefit of thisdisclosure, will appreciate that other embodiments can be devised whichdo not depart from the scope of the invention as disclosed herein.

For example, some embodiments have been described herein according toregion-based ALF using sixteen LCU-aligned regions. One of ordinaryskill in the art will understand that more or few regions may be usedand/or the regions may not be LCU-aligned.

In another example, embodiments of ALF with no offset have beendescribed herein in the context of region-based filtering. One ofordinary skill in the art will understand embodiments may also be usedin block-based ALF techniques in which the variance of a block is usedto select the filter parameters for the block.

Embodiments of the methods, encoders, and decoders described herein maybe implemented in hardware, software, firmware, or any combinationthereof. If completely or partially implemented in software, thesoftware may be executed in one or more processors, such as amicroprocessor, application specific integrated circuit (ASIC), fieldprogrammable gate array (FPGA), or digital signal processor (DSP). Thesoftware instructions may be initially stored in a computer-readablemedium and loaded and executed in the processor. In some cases, thesoftware instructions may also be sold in a computer program product,which includes the computer-readable medium and packaging materials forthe computer-readable medium. In some cases, the software instructionsmay be distributed via removable computer readable media, via atransmission path from computer readable media on another digitalsystem, etc. Examples of computer-readable media include non-writablestorage media such as read-only memory devices, writable storage mediasuch as disks, flash memory, memory, or a combination thereof.

Although method steps may be presented and described herein in asequential fashion, one or more of the steps shown in the figures anddescribed herein may be performed concurrently, may be combined, and/ormay be performed in a different order than the order shown in thefigures and/or described herein. Accordingly, embodiments should not beconsidered limited to the specific ordering of steps shown in thefigures and/or described herein.

It is therefore contemplated that the appended claims will cover anysuch modifications of the embodiments as fall within the true scope ofthe invention.

What is claimed is:
 1. A method comprising: determining whether sampleadaptive offset (SAO) filtering is applied to a reconstructed picture ina video encoder, wherein the SAO filtering compensates for an intensityshift in the reconstructed picture; estimating parameters of an adaptiveloop filter based on whether the SAO filtering is applied to thereconstructed picture, wherein the parameters of the adaptive loopfilter include a plurality of coefficients and selectively include anoffset parameter, the selection based on whether the SAO filtering isapplied to the reconstructed picture; and applying the adaptive loopfilter to at least some pixels of the reconstructed picture based on theestimated parameters, wherein the adaptive loop filter includessymmetric 2D finite impulse response (FIR) filters.
 2. The method ofclaim 1, wherein estimating parameters of an adaptive loop filtercomprises estimating parameters of the adaptive loop filter using afirst technique or a second technique; and further comprising performingadaptive loop filtering for the reconstructed picture selectively withor without the offset based on whether the SAO filtering is applied tothe reconstructed picture.
 3. The method of claim 2, wherein performingadaptive loop filtering for the reconstructed picture selectively withor without the offset includes: using adaptive loop filtering with nooffset for the reconstructed picture when the SAO filtering is appliedto the reconstructed picture; and using adaptive loop filtering with theoffset for the reconstructed picture when the SAO filtering is notapplied to the reconstructed picture.
 4. The method of claim 3, whereinusing adaptive loop filtering with no offset comprises: determiningfilter parameter values for an adaptive loop filter to be applied to aselected portion of reconstructed pixels in the reconstructed picture,wherein the offset is assumed to be zero and wherein only values of theplurality of coefficients are determined; applying the adaptive loopfilter to at least some pixels of the portion of reconstructed pixelsusing the values of the plurality of coefficients, wherein a value ofthe offset is assumed to be zero; and signaling the filter parametervalues in a compressed video bit stream.
 5. The method of claim 4,wherein applying the adaptive loop filter comprises: computing afiltered pixel value q(x,y) for each pixel p(x,y) of the at least somepixels as per q(x,y)=Σ_(i=0) ^(N)c_(i)p_(i)(x,y), wherein N+1 is anumber of the plurality of filter coefficients and c_(i) are the filtercoefficients.
 6. The method of claim 4, wherein the portion ofreconstructed pixels is a region of the reconstructed picture selectedfrom a plurality of regions of the reconstructed picture.
 7. The methodof claim 4, further comprising: signaling in the compressed video bitstream that adaptive loop filtering with no offset is used, and whereinsignaling the filter parameter values comprises signaling only thevalues of the plurality of coefficients.
 8. The method of claim 4,wherein signaling the filter parameter values comprises signaling thevalues of the plurality of coefficients and a value of zero for theoffset.
 9. The method of claim 4, wherein signaling the filter parametervalues comprises: signaling filter parameter values for each row ofregions in the reconstructed picture, wherein the filter parametervalues for a row are signaled one of immediately prior to data for therow or immediately following the data for the row.
 10. The method ofclaim 4, wherein signaling the filter parameter values comprises:signaling filter parameter values for each region in the reconstructedpicture, wherein the filter parameter values for a region are signaledone of immediately prior to data for the region or immediately followingthe data for the region.
 11. The method of claim 3, wherein usingadaptive loop filtering with a computed offset comprises: determiningfilter parameter values for an adaptive loop filter to be applied to aselected portion of reconstructed pixels in the reconstructed picture,wherein values of the plurality of coefficients and a value of theoffset are determined; applying the adaptive loop filter to at leastsome pixels of the portion of reconstructed pixels using the values ofthe plurality of coefficients and the value of the offset; and signalingthe filter parameter values in a compressed video bit stream.
 12. Themethod of claim 1, wherein estimating the parameters of the adaptiveloop filter comprises estimating parameters of the adaptive loop filterusing the first technique or the second technique includes: estimatingthe parameters of the adaptive loop filter using the first technique inresponse to determining that the SAO filtering is applied to thereconstructed picture; and estimating the parameters of the adaptiveloop filter using the second technique in response to determining thatthe SAO filtering is not applied to the reconstructed picture.
 13. Themethod of claim 12, wherein the first technique includes assuming thatthe offset parameter is zero, and wherein the second technique includesnot assuming that the offset parameter is zero.
 14. The method of claim12, wherein the first technique includes estimating the parameters ofthe adaptive loop filter using a sum of the original pixel values, andwherein the second technique includes estimating the parameters of theadaptive loop filter without using a sum of the original pixel values.15. The method of claim 12, wherein the first technique includesestimating the parameters of the adaptive loop filter using an(M−1)×(M−1) matrix, and wherein the second technique includes estimatingthe parameters of the adaptive loop filter using a M×M matrix.